
 FOR EACH glt_det NO-LOCK WHERE glt_ref BEGINS "",
     EACH trgl_det WHERE trgl_gl_ref = glt_ref AND trgl_type BEGINS 'rct-'NO-LOCK
       BY glt_ref:
     
    DISP glt_entity
      glt_ref
      glt_line
      glt_desc
      glt_amt
      glt_acct
      glt_sub
      glt_cc
      glt_proj
      glt_batch
      glt_curr_amt
      SKIP(1)
    WITH WIDTH 190.
            
    DISPLAY trgl_type trgl_trnbr trgl_sequence trgl_gl_ref trgl_gl_amt trgl_dy_num trgl_dy_code 
      SKIP(1)
    WITH WIDTH 190.
     
    DISP trgl_dr_line trgl_dr_acct trgl_dr_sub trgl_dr_cc trgl_dr_proj  
          trgl_cr_line trgl_cr_acct trgl_cr_sub trgl_cr_cc trgl_cr_proj 
      SKIP(1)
    WITH WIDTH 190.

    FOR EACH tr_hist WHERE tr_trnbr = trgl_trnbr BREAK BY trgl_gl_ref :
       ACCUMULATE tr_qty_chg * tr_price (TOTAL).    
       DISP tr_nbr
          tr_trnbr
          trgl_gl_ref
          tr_ref
          tr_batch
          tr_ship_id
          tr_lot
          tr_addr
          tr_part
          SKIP(1)
       WITH WIDTH 180.

       DISP 
          tr_qty_chg
          tr_price
          tr_qty_chg * tr_price COLUMN-LABEL "Amount"
          ACCUM TOTAL tr_qty_chg * tr_price 
       WITH WIDTH 180.
    END.
 END.

/* FOR EACH TRGL_DET NO-LOCK WHERE TRGL_GL_REF BEGINS '': */
/*     DISP trgl_.                                        */
/* END.                                                   */
